{template 'header'}
<link href="./resource/css/app.css" rel="stylesheet">
<script src="./layui/layui.js"></script>
<link href="./layui/css/layui.css">
<ul class="nav nav-tabs">
    <li {if $op == ''}class="active"{/if}><a href="javascript:;">充值记录</a></li>
</ul>
<form action="./index.php" method="get" class="form-horizontal">
    <input type="hidden" name="c" value="site">
    <input type="hidden" name="a" value="entry">
    <input type="hidden" name="m" value="bh_bargain">
    <input type="hidden" name="do" value="payOrder">

    <div class="form-group">
        <label class="col-xs-12 col-sm-1 control-label">会员昵称</label>
        <div class="col-sm-2 col-xs-12">
            <input type="text" class="form-control" name="nickname"  value="{$nickname}" />
        </div>
        <label class="col-xs-12 col-sm-1 control-label">会员id</label>
        <div class="col-sm-2 col-xs-12">
            <input type="text" class="form-control" name="member_id"  value="{$member_id}" />
        </div>
        <label class="col-xs-12 col-sm-1 control-label">订单状态</label>
        <div class="col-sm-2 col-xs-12">
            <select class="select valid" name="status" size="1" aria-invalid="false" style="width: 150px;">
                <option value="0">支付状态</option>
                <option value="1" {if $status == 1}selected="selected" {/if}>未支付</option>
                <option value="2" {if $status == 2}selected="selected" {/if}>已支付</option>
            </select>
        </div>
        <div class="col-xs-12 col-sm-2 col-md-2 col-lg-2">
            <button type="submit" class="btn btn-default"><i class="fa fa-search"></i> 搜索</button>
        </div>
    </div>
</form>

<div class="panel panel-default">
    <div class="table-responsive panel-body">
        <table class="table table-hover">
            <thead class="navbar-inner">
            <tr>
                <th style="width:70px;">会员id</th>
                <th style="width:70px;">会员昵称</th>
                <th style="width:60px;">订单号</th>
                <th style="width:60px;">类型</th>
                <th style="width:85px;">支付成功时间</th>
                <th style="width:85px;">充值金额</th>
                <th style="width:85px;">状态</th>
                <th style="width:60px;">时间</th>
            </tr>
            </thead>
            <tbody>
            {loop $payOrder['list'] $item}
            <tr>
                <td>{$item['member_id']}</td>
                <td>{$item['nickname']}</td>
                <td>{$item['trade_no']}</td>
                <td>{$item['type']}</td>
                <td>{php echo date('Y-m-d H:i:s', $item['pay_time'])}</td>
                <td>{$item['money']}</td>
                <td>{php echo $item['status']==1 ? '未支付' : '已支付'}</td>
                <td>{php echo date('Y-m-d H:i:s', $item['created'])}</td>
            </tr>
            {/loop}
            </tbody>
        </table>
    </div>
    {$payOrder['pages']}
</div>
